package com.lhldyf.demo;

import org.springframework.core.type.classreading.MetadataReader;
import org.springframework.core.type.classreading.MetadataReaderFactory;
import org.springframework.core.type.filter.TypeFilter;

import java.io.IOException;

/**
 * @author lhldyf
 * @date 2020-05-28 23:00
 */
public class Module3CustomFilterType implements TypeFilter {
    @Override
    public boolean match(MetadataReader metadataReader, MetadataReaderFactory metadataReaderFactory)
            throws IOException {
        return "com.lhldyf.demo.ClassInModule2".equals(metadataReader.getClassMetadata().getClassName());
    }
}
